<?php
$logs = R::findAll('log', 'project_id=?',[42]);
foreach($logs as $log) {
	$log->moved_day = getDaysDiff($log->date, $log->project->created_date);
	//$card->prev_moved_day =
	if ($log->prev_column_id == $log->current_column_id) $log->moved_day=0;
	R::store($log);
}
